220
|
How can I remove all the columns

local oComboBox
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Clear()
|
219
|
How can I remove a column

local oComboBox
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Remove("A")
|
482
|
How can I put icons/images into buttons

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.SingleEdit = true
oComboBox.Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
oComboBox.Columns.Add("")
var_Column = oComboBox.Columns.Add("C+B")
var_Column.AllowSizing = false
var_Column.Width = 48
var_Column.FormatColumn = "` <img>` + ( 1 + (1 index ``) mod 3 ) + `</img> `"
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
// var_Column.Def(0) = true
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(0) = True]
endwith
// var_Column.Def(2) = true
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(2) = True]
endwith
// var_Column.Def(3) = true
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(3) = True]
endwith
var_Column.Position = 0
oComboBox.DrawGridLines = 2
oComboBox.DefaultItemHeight = 20
var_Items = oComboBox.Items
var_Items.AddItem("Item 1")
var_Items.AddItem("Item 2")
var_Items.AddItem("Item 3")
var_Items.AddItem("Item 4")
var_Items.AddItem("Item 5")
var_Items.AddItem("Item 6")
var_Items.AddItem("Item 7")
var_Items.AddItem("Item 8")
oComboBox.EndUpdate()
|
205
|
How can I programmatically filter a column

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("Filter")
var_Column.DisplayFilterButton = true
var_Column.FilterType = 2
oComboBox.Items.AddItem()
oComboBox.Items.AddItem("not empty")
oComboBox.ApplyFilter()
|
503
|
How can I programmatically clear the control's filter
/*
with (this.EXCOMBOBOXACTIVEXCONTROL1.nativeObject)
Click = class::nativeObject_Click
endwith
*/
// Occurs when the user presses and then releases the left mouse button over the list control.
function nativeObject_Click()
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.ClearFilter()
return
local oComboBox,var_Column,var_Column1,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Item").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("Item")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarPromptVisible = 1
oComboBox.FilterBarPromptPattern = "B"
oComboBox.EndUpdate()
|
91
|
How can I programmatically change the column where incremental searching is performed

local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Column 1")
oComboBox.Columns.Add("Column 2")
var_Items = oComboBox.Items
// var_Items.CellCaption(var_Items.AddItem("Item 1"),1) = "SubItem 1"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Item 1"),1) = "SubItem 1"]
endwith
oComboBox.SearchColumnIndex = 1
|
488
|
How can I prevent showing the lines for the hierarchy while using the exMatchingItemsOnly option

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.LinesAtRoot = -1
oComboBox.TreeColumnIndex = -1
oComboBox.FilterInclude = 4
var_Column = oComboBox.Columns.Add("Column")
var_Column.DisplayFilterButton = true
var_Column.FilterType = 240
var_Column.Filter = "C1|C2"
var_Items = oComboBox.Items
h = var_Items.AddItem("R1")
var_Items.InsertItem(h,null,"C1")
var_Items.InsertItem(h,null,"C2")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
h = var_Items.AddItem("R2")
var_Items.InsertItem(h,null,"C1")
var_Items.InsertItem(h,null,"C2")
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
315
|
How can I merge cells

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.MarkSearchColumn = false
oComboBox.TreeColumnIndex = -1
oComboBox.Columns.Add("C1")
oComboBox.Columns.Add("C2")
var_Items = oComboBox.Items
h = var_Items.AddItem("Cell 1")
// var_Items.CellCaption(h,1) = "This is bit of text that's shown on multiple lines. This is bit of text that's shown on multiple lines."
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "This is bit of text that's shown on multiple lines. This is bit of text that's shown on multiple lines."]
endwith
// var_Items.CellSingleLine(h,1) = false
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellSingleLine(h,1) = False]
endwith
h = var_Items.AddItem("This is bit of text merges all cells in the item")
// var_Items.ItemDivider(h) = 0
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ItemDivider(h) = 0]
endwith
// var_Items.CellHAlignment(h,0) = 1
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellHAlignment(h,0) = 1]
endwith
|
316
|
How can I merge cells

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.DrawGridLines = -1
oComboBox.MarkSearchColumn = false
oComboBox.Columns.Add("C1")
oComboBox.Columns.Add("C2")
oComboBox.Columns.Add("C3")
var_Items = oComboBox.Items
h = var_Items.AddItem("this cell merges the first two columns")
// var_Items.CellMerge(h,0) = 1
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellMerge(h,0) = 1]
endwith
h = var_Items.AddItem()
// var_Items.CellCaption(h,1) = "this cell merges the last two columns"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "this cell merges the last two columns"]
endwith
// var_Items.CellMerge(h,1) = 2
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellMerge(h,1) = 2]
endwith
h = var_Items.AddItem("this cell merges the all three columns")
// var_Items.CellMerge(h,0) = 1
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellMerge(h,0) = 1]
endwith
// var_Items.CellMerge(h,0) = 2
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellMerge(h,0) = 2]
endwith
h = var_Items.AddItem("this draws a divider item")
// var_Items.ItemDivider(h) = 0
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ItemDivider(h) = 0]
endwith
|
364
|
How can I mark the cells that has a specified type, ie strings only

local h,oComboBox,var_ConditionalFormat,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.ConditionalFormats.Add("type(%0) = 8").ForeColor = 0xff
var_ConditionalFormat = oComboBox.ConditionalFormats.Add("type(%0) = 8")
with (oComboBox)
TemplateDef = [dim var_ConditionalFormat]
TemplateDef = var_ConditionalFormat
Template = [var_ConditionalFormat.ForeColor = 255]
endwith
oComboBox.Columns.Add("")
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,2)
var_Items.InsertItem(h,null,"Chld 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
467
|
How can I make bigger/enlarge the control's drop down button

local oComboBox
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.LabelHeight = 40
oComboBox.ScrollWidth = 40
oComboBox.EndUpdate()
|
254
|
How can I make an item unselectable, or not selectable

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
h = var_Items.AddItem("unselectable - you can't get selected")
// var_Items.SelectableItem(h) = false
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.SelectableItem(h) = False]
endwith
var_Items.AddItem("selectable")
|
7
|
How can I insert an icon to column's header

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
// oComboBox.Columns.Add("ColumnName").HTMLCaption = "<b>HTML</b> Column <img>1</img> Icon"
var_Column = oComboBox.Columns.Add("ColumnName")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.HTMLCaption = "<b>HTML</b> Column <img>1</img> Icon"]
endwith
|
6
|
How can I insert an icon to column's header

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
// oComboBox.Columns.Add("ColumnName").HeaderImage = 1
var_Column = oComboBox.Columns.Add("ColumnName")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.HeaderImage = 1]
endwith
|
295
|
How can I insert a hyperlink or an anchor element

local oComboBox,var_Items,var_Items1
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
// var_Items.CellCaptionFormat(var_Items.AddItem("Just an <a1>anchor</a> element ..."),0) = 1
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaptionFormat(AddItem("Just an <a1>anchor</a> element ..."),0) = 1]
endwith
var_Items1 = oComboBox.Items
// var_Items1.CellCaptionFormat(var_Items1.AddItem("Just another <a2>anchor</a> element ..."),0) = 1
with (oComboBox)
TemplateDef = [dim var_Items1]
TemplateDef = var_Items1
Template = [var_Items1.CellCaptionFormat(AddItem("Just another <a2>anchor</a> element ..."),0) = 1]
endwith
|
360
|
How can I highlight the cells or items that starts with a specified string

local h,oComboBox,var_ConditionalFormat,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.ConditionalFormats.Add("%0 startwith 'C'").Underline = true
var_ConditionalFormat = oComboBox.ConditionalFormats.Add("%0 startwith 'C'")
with (oComboBox)
TemplateDef = [dim var_ConditionalFormat]
TemplateDef = var_ConditionalFormat
Template = [var_ConditionalFormat.Underline = True]
endwith
oComboBox.Columns.Add("")
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
var_Items.InsertItem(h,null,"SChild 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
421
|
How can I highlight only parts of the cells

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("")
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Column.FormatColumn = "value replace 'hil' with '<fgcolor=FF0000><b>hil</b></fgcolor>'"
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
var_Items.InsertItem(h,null,"Child 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
11
|
How can I hide the searching column

local oComboBox
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.MarkSearchColumn = false
oComboBox.Columns.Add("Column 1")
oComboBox.Columns.Add("Column 2")
oComboBox.Items.AddItem()
|
126
|
How can I hide the locked / fixed items

local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.ShowLockedItems = false
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
// var_Items.LockedItemCount(0) = 1
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.LockedItemCount(0) = 1]
endwith
// var_Items.CellCaption(var_Items.LockedItem(0,0),0) = "locked item"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(LockedItem(0,0),0) = "locked item"]
endwith
var_Items.AddItem("un-locked item")
|
342
|
How can I hide the drop down buttons when the control loses the focus

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.HideDropDownButton = true
oComboBox.IntegralHeight = true
oComboBox.LinesAtRoot = 1
oComboBox.TreeColumnIndex = 1
oComboBox.Columns.Add("Column 1")
oComboBox.Columns.Add("Column 2")
var_Items = oComboBox.Items
h = var_Items.AddItem("Root 1.1")
// var_Items.CellCaption(h,1) = "Root 1.2"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "Root 1.2"]
endwith
// var_Items.CellCaption(var_Items.InsertItem(h,null,"Child 1.1"),1) = "Child 1.2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(InsertItem(h,,"Child 1.1"),1) = "Child 1.2"]
endwith
// var_Items.CellCaption(var_Items.InsertItem(h,null,"Child 2.1"),1) = "Child 2.2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(InsertItem(h,,"Child 2.1"),1) = "Child 2.2"]
endwith
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
h = var_Items.AddItem("Root 2.1")
// var_Items.CellCaption(h,1) = "Root 2.2"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "Root 2.2"]
endwith
// var_Items.CellCaption(var_Items.InsertItem(h,null,"Child 1.1"),1) = "Child 1.2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(InsertItem(h,,"Child 1.1"),1) = "Child 1.2"]
endwith
|
253
|
How can I hide or show an item

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
h = var_Items.AddItem("hidden")
// var_Items.ItemHeight(h) = 0
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ItemHeight(h) = 0]
endwith
// var_Items.SelectableItem(h) = false
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.SelectableItem(h) = False]
endwith
var_Items.AddItem("visible")
|
120
|
How can I hide a column

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Hidden").Visible = false
var_Column = oComboBox.Columns.Add("Hidden")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Visible = False]
endwith
oComboBox.Columns.Add("2")
oComboBox.Columns.Add("3")
oComboBox.Columns.Add("4")
oComboBox.Columns.Add("5")
|
461
|
How can I have a case-sensitive filter

local oComboBox,var_Column,var_Column1,var_Columns,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.MarkSearchColumn = false
var_Columns = oComboBox.Columns
var_Column = var_Columns.Add("Car")
var_Column.DisplayFilterButton = true
var_Column.FilterType = 496 /*exFilterDoCaseSensitive | exFilter*/
var_Column.Filter = "Mazda"
var_Column1 = var_Columns.Add("Equipment")
var_Column1.DisplayFilterButton = true
var_Column1.DisplayFilterPattern = false
var_Column1.CustomFilter = "Air Bag||*Air Bag*|||Air condition||*Air condition*|||ABS||*ABS*|||ESP||*ESP*"
var_Column1.FilterType = 259 /*exFilterDoCaseSensitive | exPattern*/
var_Column1.Filter = "Air Bag"
var_Items = oComboBox.Items
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "Air Bag"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "Air Bag"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Toyota"),1) = "Air Bag,Air condition"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Toyota"),1) = "Air Bag,Air condition"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Ford"),1) = "Air condition"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Ford"),1) = "Air condition"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Nissan"),1) = "Air Bag,ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Nissan"),1) = "Air Bag,ABS,ESP"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "Air Bag, ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "Air Bag, ABS,ESP"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "ABS,ESP"]
endwith
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
462
|
How can I have a case-insensitive filter (exFilterDoCaseSensitive flag is not set)

local oComboBox,var_Column,var_Column1,var_Columns,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.MarkSearchColumn = false
var_Columns = oComboBox.Columns
var_Column = var_Columns.Add("Car")
var_Column.DisplayFilterButton = true
var_Column.FilterType = 240
var_Column.Filter = "MAZDA"
var_Column1 = var_Columns.Add("Equipment")
var_Column1.DisplayFilterButton = true
var_Column1.DisplayFilterPattern = false
var_Column1.CustomFilter = "Air Bag||*Air Bag*|||Air condition||*Air condition*|||ABS||*ABS*|||ESP||*ESP*"
var_Column1.FilterType = 3
var_Column1.Filter = "AIR BAG"
var_Items = oComboBox.Items
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "Air Bag"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "Air Bag"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Toyota"),1) = "Air Bag,Air condition"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Toyota"),1) = "Air Bag,Air condition"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Ford"),1) = "Air condition"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Ford"),1) = "Air condition"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Nissan"),1) = "Air Bag,ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Nissan"),1) = "Air Bag,ABS,ESP"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "Air Bag, ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "Air Bag, ABS,ESP"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "ABS,ESP"]
endwith
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
29
|
How can I get underlined only a portion of column's header

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Column 1").HTMLCaption = "<u>Col</u>umn 1"
var_Column = oComboBox.Columns.Add("Column 1")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.HTMLCaption = "<u>Col</u>umn 1"]
endwith
|
218
|
How can I get the number or the count of columns
local oComboBox,var_Count
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Count = oComboBox.Columns.Count
|
519
|
How can I get the number of results/items being shown in the control's filter bar (sample 4)

local oComboBox,var_Column,var_Column1,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
var_Column = oComboBox.Columns.Add("Item")
var_Column.DisplayFilterButton = true
var_Column.FilterList = 9504 /*exShowExclude | exShowFocusItem | exShowCheckBox | exSortItemsAsc*/
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarFont = oComboBox.Font
oComboBox.FilterBarPrompt = Str(oComboBox.FormatABC("`<b>` + value",oComboBox.FilterBarPrompt))
oComboBox.FilterBarCaption = "`<b><r>` + value + `</b><fgcolor=808080>` + ( matchitemcount < 0 ? ( ( len(value) ? `<br>` : `` ) + `<r>` + abs(matchitemcount + 1) + ` result(s)` ) : (`<fgcolor=808080>`+ itemcount + ` item(s)`) )"
oComboBox.FilterBarPromptVisible = 3591 /*exFilterBarCompact | exFilterBarShowCloseOnRight | exFilterBarShowCloseIfRequired | exFilterBarCaptionVisible | exFilterBarVisible | exFilterBarPromptVisible*/
oComboBox.EndUpdate()
|
518
|
How can I get the number of results being shown in the control's filter bar (sample 3)

local oComboBox,var_Column,var_Column1,var_Column2,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Item").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("Item")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarFont = oComboBox.Font
oComboBox.FilterBarCaption = "`<b><r>` + value + `</b><fgcolor=808080>` + ( matchitemcount < 0 ? ( ( len(value) ? `<br>` : `` ) + `<r>` + abs(matchitemcount + 1) + ` result(s)` ) : ``)"
oComboBox.FilterBarPromptVisible = 2055 /*exFilterBarCompact | exFilterBarCaptionVisible | exFilterBarVisible | exFilterBarPromptVisible*/
var_Column2 = oComboBox.Columns.Item(0)
var_Column2.FilterType = 240
var_Column2.Filter = "Item A|Item B"
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
517
|
How can I get the number of results being shown in the control's filter bar (sample 2, compact)

local oComboBox,var_Column,var_Column1,var_Column2,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Item").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("Item")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarFont = oComboBox.Font
oComboBox.FilterBarCaption = "`<b><r>` + value + `</b><fgcolor=808080>` + ( matchitemcount < 0 ? `<off -4> ` + abs(matchitemcount + 1) + ` result(s)` : ``)"
oComboBox.FilterBarPromptVisible = 2071 /*exFilterBarCompact | exFilterBarSingleLine | exFilterBarCaptionVisible | exFilterBarVisible | exFilterBarPromptVisible*/
var_Column2 = oComboBox.Columns.Item(0)
var_Column2.FilterType = 240
var_Column2.Filter = "Item A|Item B"
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
516
|
How can I get the number of results being shown in the control's filter bar (sample 1)

local oComboBox,var_Column,var_Column1,var_Column2,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Item").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("Item")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarFont = oComboBox.Font
oComboBox.FilterBarCaption = "`<b>` + value + `</b><r><fgcolor=808080>` + ( matchitemcount < 0 ? abs(matchitemcount + 1) + ` result(s)` : ``)"
oComboBox.FilterBarPromptVisible = 7 /*exFilterBarCaptionVisible | exFilterBarVisible | exFilterBarPromptVisible*/
var_Column2 = oComboBox.Columns.Item(0)
var_Column2.FilterType = 240
var_Column2.Filter = "Item A|Item B"
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
504
|
How can I get the number of results after a filter is applied

/*
with (this.EXCOMBOBOXACTIVEXCONTROL1.nativeObject)
Click = class::nativeObject_Click
endwith
*/
// Occurs when the user presses and then releases the left mouse button over the list control.
function nativeObject_Click()
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.ClearFilter()
return
/*
with (this.EXCOMBOBOXACTIVEXCONTROL1.nativeObject)
FilterChange = class::nativeObject_FilterChange
endwith
*/
// Occurs when filter was changed.
function nativeObject_FilterChange()
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
? "Items.MatchItemCount"
? Str(oComboBox.Items.MatchItemCount)
? Str(oComboBox.FormatABC("value < 0 ? `filter applied: ` + abs(value + 1) + ` result(s)` : `no filter`",oComboBox.Items.MatchItemCount))
return
local oComboBox,var_Column,var_Column1,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Item").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("Item")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarPromptVisible = 1
oComboBox.FilterBarPromptPattern = "Item"
oComboBox.EndUpdate()
|
420
|
How can I get the number of occurrences of a specified string in the cell

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("")
var_Column = oComboBox.Columns.Add("occurrences")
var_Column.ComputedField = "lower(%0) count 'o'"
var_Column.FormatColumn = "'contains ' + value + ' of \'o\' chars'"
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1 oooof the root")
var_Items.InsertItem(h,null,"Child 2")
var_Items.InsertItem(h,null,"Child 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
399
|
How can I get the number of occurrences of a specified string in the cell

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("")
var_Column = oComboBox.Columns.Add("occurrences")
var_Column.ComputedField = "lower(%0) count 'o'"
var_Column.FormatColumn = "'contains ' + value + ' of \'o\' chars'"
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1 oooof the root")
var_Items.InsertItem(h,null,"Child 2")
var_Items.InsertItem(h,null,"Child 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
277
|
How can I get the handle of an item based on the handle of the cell

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Default")
var_Items = oComboBox.Items
h = var_Items.AddItem("Root 1")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
// var_Items.ItemBold(var_Items.CellItem(var_Items.ItemCell(h,0))) = true
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.ItemBold(CellItem(ItemCell(h,0))) = True]
endwith
|
222
|
How can I get the columns as they are shown in the control's sortbar
local oComboBox,var_Object
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Object = oComboBox.Columns.ItemBySortPosition(0)
|
386
|
How can I get second part of the date

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("Second").ComputedField = "sec(date(%0))"
var_Column = oComboBox.Columns.Add("Second")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "sec(date(%0))"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/11/2001 10:10:00")
var_Items.AddItem("02/22/2002 11:01:22")
var_Items.AddItem("03/13/2003 12:23:01")
var_Items.AddItem("04/14/2004 13:11:59")
|
65
|
How can I get ride/hide of the "Filter For" field

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("Column")
var_Column.DisplayFilterButton = true
var_Column.DisplayFilterPattern = false
|
368
|
How can I get or display the integer part of the cell

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Number")
// oComboBox.Columns.Add("Int").ComputedField = "int(%0)"
var_Column = oComboBox.Columns.Add("Int")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "int(%0)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("-1.98")
var_Items.AddItem("0.99")
var_Items.AddItem("1.23")
var_Items.AddItem("2.34")
|
379
|
How can I get only the year part from a date expression

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("Year").ComputedField = "year(%0)"
var_Column = oComboBox.Columns.Add("Year")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "year(%0)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001 10:00:00")
var_Items.AddItem("02/02/2002 11:00:00")
var_Items.AddItem("03/03/2003 12:00:00")
var_Items.AddItem("04/04/2004 13:00:00")
|
385
|
How can I get minute part of the date

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("Minute").ComputedField = "min(date(%0))"
var_Column = oComboBox.Columns.Add("Minute")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "min(date(%0))"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/11/2001 10:10:00")
var_Items.AddItem("02/22/2002 11:01:00")
var_Items.AddItem("03/13/2003 12:23:00")
var_Items.AddItem("04/14/2004 13:11:00")
|
309
|
How can I fix or lock items

local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Default")
var_Items = oComboBox.Items
// var_Items.LockedItemCount(0) = 1
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.LockedItemCount(0) = 1]
endwith
// var_Items.CellCaption(var_Items.LockedItem(0,0),0) = "This is a locked item, fixed to the top side of the control."
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(LockedItem(0,0),0) = "This is a locked item, fixed to the top side of the control."]
endwith
// var_Items.ItemBackColor(var_Items.LockedItem(0,0)) = 0xbac4c4
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.ItemBackColor(LockedItem(0,0)) = 12240068]
endwith
// var_Items.LockedItemCount(2) = 2
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.LockedItemCount(2) = 2]
endwith
// var_Items.CellCaption(var_Items.LockedItem(2,0),0) = "This is a locked item, fixed to the top side of the control."
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(LockedItem(2,0),0) = "This is a locked item, fixed to the top side of the control."]
endwith
// var_Items.ItemBackColor(var_Items.LockedItem(2,0)) = 0xbac4c4
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.ItemBackColor(LockedItem(2,0)) = 12240068]
endwith
// var_Items.CellCaption(var_Items.LockedItem(2,1),0) = "This is a locked item, fixed to the top side of the control."
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(LockedItem(2,1),0) = "This is a locked item, fixed to the top side of the control."]
endwith
// var_Items.ItemBackColor(var_Items.LockedItem(2,1)) = 0xbababa
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.ItemBackColor(LockedItem(2,1)) = 12237498]
endwith
|
307
|
How can I fix or lock an item on the top of the control

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Default")
var_Items = oComboBox.Items
// var_Items.LockedItemCount(0) = 1
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.LockedItemCount(0) = 1]
endwith
// var_Items.CellCaption(var_Items.LockedItem(0,0),0) = "This is a locked item, fixed to the top side of the control."
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(LockedItem(0,0),0) = "This is a locked item, fixed to the top side of the control."]
endwith
h = var_Items.AddItem("Root 1")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
308
|
How can I fix or lock an item on the bottom side of the control

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Default")
var_Items = oComboBox.Items
// var_Items.LockedItemCount(2) = 1
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.LockedItemCount(2) = 1]
endwith
// var_Items.CellCaption(var_Items.LockedItem(2,0),0) = "This is a locked item, fixed to the bottom side of the control."
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(LockedItem(2,0),0) = "This is a locked item, fixed to the bottom side of the control."]
endwith
h = var_Items.AddItem("Root 1")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
292
|
How can I find the cell being clicked in a radio group

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.MarkSearchColumn = false
oComboBox.SelBackColor = 0x80ffff
oComboBox.SelForeColor = 0x0
oComboBox.Columns.Add("C1")
oComboBox.Columns.Add("C2")
oComboBox.Columns.Add("C3")
var_Items = oComboBox.Items
h = var_Items.AddItem("Cell 1")
// var_Items.CellCaption(h,1) = "Radio 1"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "Radio 1"]
endwith
// var_Items.CellHasRadioButton(h,1) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellHasRadioButton(h,1) = True]
endwith
// var_Items.CellRadioGroup(h,1) = 1234
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellRadioGroup(h,1) = 1234]
endwith
// var_Items.CellCaption(h,2) = "Radio 2"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,2) = "Radio 2"]
endwith
// var_Items.CellHasRadioButton(h,2) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellHasRadioButton(h,2) = True]
endwith
// var_Items.CellRadioGroup(h,2) = 1234
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellRadioGroup(h,2) = 1234]
endwith
// var_Items.CellState(h,1) = 1
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellState(h,1) = 1]
endwith
// var_Items.CellBold(null,var_Items.CellChecked(1234)) = true
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellBold(,CellChecked(1234)) = True]
endwith
|
489
|
How can I find if there is any filter applied to the control

/*
with (this.EXCOMBOBOXACTIVEXCONTROL1.nativeObject)
FilterChange = class::nativeObject_FilterChange
endwith
*/
// Occurs when filter was changed.
function nativeObject_FilterChange()
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
? "If negative, the filter is present, else not"
? Str(oComboBox.Items.VisibleItemCount)
return
local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.LinesAtRoot = -1
oComboBox.TreeColumnIndex = -1
oComboBox.FilterInclude = 4
var_Column = oComboBox.Columns.Add("Column")
var_Column.DisplayFilterButton = true
var_Column.FilterType = 240
var_Column.Filter = "C1"
var_Items = oComboBox.Items
h = var_Items.AddItem("R1")
var_Items.InsertItem(h,null,"C1")
var_Items.InsertItem(h,null,"C2")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
h = var_Items.AddItem("R2")
var_Items.InsertItem(h,null,"C1")
var_Items.InsertItem(h,null,"C2")
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
497
|
How can I find if the control is running in DPI mode
local oComboBox
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
? Str(oComboBox.FormatABC("dpi = 1 ? `normal/stretch mode` : `dpi mode`"))
|
44
|
How can I filter the items that are between an interval/range of dates

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("Column")
var_Column.DisplayFilterButton = true
var_Column.DisplayFilterDate = true
oComboBox.ApplyFilter()
|
412
|
How can I filter programatically using more columns

local oComboBox,var_Column,var_Column1,var_Columns,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.MarkSearchColumn = false
var_Columns = oComboBox.Columns
var_Columns.Add("Car")
var_Columns.Add("Equipment")
var_Items = oComboBox.Items
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "Air Bag"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "Air Bag"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Toyota"),1) = "Air Bag,Air condition"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Toyota"),1) = "Air Bag,Air condition"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Ford"),1) = "Air condition"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Ford"),1) = "Air condition"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Nissan"),1) = "Air Bag,ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Nissan"),1) = "Air Bag,ABS,ESP"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "Air Bag, ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "Air Bag, ABS,ESP"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Mazda"),1) = "ABS,ESP"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Mazda"),1) = "ABS,ESP"]
endwith
var_Column = oComboBox.Columns.Item("Car")
var_Column.FilterType = 240
var_Column.Filter = "Mazda"
var_Column1 = oComboBox.Columns.Item("Equipment")
var_Column1.FilterType = 3
var_Column1.Filter = "*ABS*|*ESP*"
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
426
|
How can I expand all items

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.LinesAtRoot = -1
oComboBox.Columns.Add("Items")
var_Items = oComboBox.Items
h = var_Items.AddItem("Root 1")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
h = var_Items.AddItem("Root 2")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
// var_Items.ExpandItem(0) = true
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.ExpandItem(0) = True]
endwith
oComboBox.EndUpdate()
|
341
|
How can I ensure that the drop down portions doesn't show partial items

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.IntegralHeight = true
oComboBox.LinesAtRoot = 1
oComboBox.TreeColumnIndex = 1
oComboBox.Columns.Add("Column 1")
oComboBox.Columns.Add("Column 2")
var_Items = oComboBox.Items
h = var_Items.AddItem("Root 1.1")
// var_Items.CellCaption(h,1) = "Root 1.2"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "Root 1.2"]
endwith
// var_Items.CellCaption(var_Items.InsertItem(h,null,"Child 1.1"),1) = "Child 1.2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(InsertItem(h,,"Child 1.1"),1) = "Child 1.2"]
endwith
// var_Items.CellCaption(var_Items.InsertItem(h,null,"Child 2.1"),1) = "Child 2.2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(InsertItem(h,,"Child 2.1"),1) = "Child 2.2"]
endwith
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
h = var_Items.AddItem("Root 2.1")
// var_Items.CellCaption(h,1) = "Root 2.2"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "Root 2.2"]
endwith
// var_Items.CellCaption(var_Items.InsertItem(h,null,"Child 1.1"),1) = "Child 1.2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(InsertItem(h,,"Child 1.1"),1) = "Child 1.2"]
endwith
|
580
|
How can I enable the clear-button (visible only if required)

local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.Style = 2
oComboBox.HeaderVisible = false
oComboBox.IntegralHeight = true
oComboBox.ShowClearButton = 1
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
var_Items.AddItem("Zero")
var_Items.AddItem("One")
var_Items.AddItem("Two")
oComboBox.Template = [Select(0) = "Zero"] // oComboBox.Select(0) = "Zero"
oComboBox.EndUpdate()
|
584
|
How can I enable the clear-button (visible only if required and focused)
local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.Style = 2
oComboBox.HeaderVisible = false
oComboBox.IntegralHeight = true
oComboBox.ShowClearButton = 3
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
var_Items.AddItem("Zero")
var_Items.AddItem("One")
var_Items.AddItem("Two")
oComboBox.Template = [Select(0) = "Zero"] // oComboBox.Select(0) = "Zero"
oComboBox.EndUpdate()
|
583
|
How can I enable the clear-button (visible only if focused)
local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.Style = 2
oComboBox.HeaderVisible = false
oComboBox.IntegralHeight = true
oComboBox.ShowClearButton = 2
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
var_Items.AddItem("Zero")
var_Items.AddItem("One")
var_Items.AddItem("Two")
oComboBox.Template = [Select(0) = "Zero"] // oComboBox.Select(0) = "Zero"
oComboBox.EndUpdate()
|
581
|
How can I enable the clear-button (always visible)

local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.Style = 2
oComboBox.HeaderVisible = false
oComboBox.IntegralHeight = true
oComboBox.ShowClearButton = -1
oComboBox.Columns.Add("Column")
var_Items = oComboBox.Items
var_Items.AddItem("Zero")
var_Items.AddItem("One")
var_Items.AddItem("Two")
oComboBox.Template = [Select(0) = "Zero"] // oComboBox.Select(0) = "Zero"
oComboBox.EndUpdate()
|
18
|
How can I draw grid lines only for visible items

local oComboBox
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.MarkSearchColumn = false
oComboBox.DrawGridLines = -2
oComboBox.Columns.Add("Column 1")
oComboBox.Columns.Add("Column 2")
oComboBox.Items.AddItem(0)
oComboBox.Items.AddItem(1)
oComboBox.Items.AddItem(2)
|
554
|
How can I display UNICODE characters

local oComboBox,var_Column,var_Items,var_StdFont
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
var_StdFont = oComboBox.Font
var_StdFont.Name = "Arial Unicode"
var_StdFont.Size = 22
oComboBox.HeaderVisible = false
oComboBox.DefaultItemHeight = 48
// oComboBox.Columns.Add("").Def(17) = 1
var_Column = oComboBox.Columns.Add("")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("Ӓӓ")
var_Items.AddItem("ᦜᦝ;ᦞ")
var_Items.AddItem("ɮɭ;ɯ")
var_Items.AddItem("勳勴勵勶")
// var_Items.FormatCell(var_Items.AddItem(oComboBox.Version),0) = "(value lfind `UNICODE`) < 0 ? `<fgcolor=FF0000><b>!UNICODE!</b> version</fgcolor> required: ` + value : `` "
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.FormatCell(AddItem(Me.Version),0) = "(value lfind `UNICODE`) < 0 ? `<fgcolor=FF0000><b>!UNICODE!</b> version</fgcolor> required: ` + value : `` "]
endwith
oComboBox.EndUpdate()
|
415
|
How can I display true or false instead 0 and -1

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Boolean").FormatColumn = "value != 0 ? 'true' : 'false'"
var_Column = oComboBox.Columns.Add("Boolean")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "value != 0 ? 'true' : 'false'"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem(true)
var_Items.AddItem(false)
var_Items.AddItem(true)
var_Items.AddItem(0)
var_Items.AddItem(1)
|
393
|
How can I display true or false instead 0 and -1

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Boolean").FormatColumn = "value != 0 ? 'true' : 'false'"
var_Column = oComboBox.Columns.Add("Boolean")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "value != 0 ? 'true' : 'false'"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem(true)
var_Items.AddItem(false)
var_Items.AddItem(true)
var_Items.AddItem(0)
var_Items.AddItem(1)
|
374
|
How can I display the time only of a date expression

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("Time").ComputedField = "'time is:' + time(date(%0))"
var_Column = oComboBox.Columns.Add("Time")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "'time is:' + time(date(%0))"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001 10:00:00")
var_Items.AddItem("02/02/2002 11:00:00")
var_Items.AddItem("03/03/2003 12:00:00")
var_Items.AddItem("04/04/2004 13:00:00")
|
387
|
How can I display the number of days between two dates

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Start")
oComboBox.Columns.Add("End")
// oComboBox.Columns.Add("Duration").ComputedField = "(date(%1)-date(%0)) + ' days'"
var_Column = oComboBox.Columns.Add("Duration")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "(date(%1)-date(%0)) + ' days'"]
endwith
var_Items = oComboBox.Items
h = var_Items.AddItem("01/11/2001")
// var_Items.CellCaption(h,1) = "01/14/2001"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = #1/14/2001#]
endwith
h = var_Items.AddItem("02/22/2002")
// var_Items.CellCaption(h,1) = "03/14/2002"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = #3/14/2002#]
endwith
h = var_Items.AddItem("03/13/2003")
// var_Items.CellCaption(h,1) = "04/11/2003"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = #4/11/2003#]
endwith
|
390
|
How can I display the currency only for not empty cells

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Number")
// oComboBox.Columns.Add("Currency").ComputedField = "len(%0) ? currency(dbl(%0)) : ''"
var_Column = oComboBox.Columns.Add("Currency")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "len(%0) ? currency(dbl(%0)) : ''"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("1.23")
var_Items.AddItem("2.34")
var_Items.AddItem("0")
// var_Items.ItemBackColor(var_Items.AddItem()) = 0x8080ff
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.ItemBackColor(AddItem()) = 8421631]
endwith
var_Items.AddItem("10000.99")
|
505
|
How can I display the control's filter on a single line (prompt-combined)

local oComboBox,var_Column,var_Column1,var_Column2,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Item").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("Item")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarCaption = "`<r>` + value"
oComboBox.FilterBarPromptVisible = 2067 /*exFilterBarCompact | exFilterBarSingleLine | exFilterBarVisible | exFilterBarPromptVisible*/
var_Column2 = oComboBox.Columns.Item(0)
var_Column2.FilterType = 240
var_Column2.Filter = "Item A|Item B"
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
506
|
How can I display the control's filter on a single line

local oComboBox,var_Column,var_Column1,var_Column2,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Item").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("Item")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
var_Column1 = oComboBox.Columns.Add("Pos")
var_Column1.AllowSizing = false
var_Column1.AllowSort = false
var_Column1.Width = 32
var_Column1.FormatColumn = "1 apos ``"
var_Column1.Position = 0
var_Items = oComboBox.Items
var_Items.AddItem("Item A")
var_Items.AddItem("Item B")
var_Items.AddItem("Item C")
oComboBox.FilterBarCaption = "len(value) ? `filter for: <fgcolor 808080>` + value : `<fgcolor 808080>no filter`"
oComboBox.FilterBarPromptVisible = 18 /*exFilterBarSingleLine | exFilterBarVisible*/
var_Column2 = oComboBox.Columns.Item(0)
var_Column2.FilterType = 240
var_Column2.Filter = "Item A|Item B"
oComboBox.ApplyFilter()
oComboBox.EndUpdate()
|
400
|
How can I display the column using currency format and enlarge the font for certain values

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("Currency")
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Column.FormatColumn = "len(value) ? ((0:=dbl(value)) < 10 ? '<fgcolor=808080><font ;7>' : '<b>') + currency(=:0)"
var_Items = oComboBox.Items
var_Items.AddItem("1.23")
var_Items.AddItem("2.34")
var_Items.AddItem("9.94")
var_Items.AddItem("11.94")
var_Items.AddItem("1000")
|
422
|
How can I display the column using currency format and enlarge the font for certain values

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("Currency")
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Column.FormatColumn = "len(value) ? ((0:=dbl(value)) < 10 ? '<fgcolor=808080><font ;7>' : '<b>') + currency(=:0)"
var_Items = oComboBox.Items
var_Items.AddItem("1.23")
var_Items.AddItem("2.34")
var_Items.AddItem("9.94")
var_Items.AddItem("11.94")
var_Items.AddItem("1000")
|
391
|
How can I display the column using currency

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Currency").FormatColumn = "currency(dbl(value))"
var_Column = oComboBox.Columns.Add("Currency")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "currency(dbl(value))"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("1.23")
var_Items.AddItem("2.34")
var_Items.AddItem("0")
var_Items.AddItem(5)
var_Items.AddItem("10000.99")
|
413
|
How can I display the column using currency

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Currency").FormatColumn = "currency(dbl(value))"
var_Column = oComboBox.Columns.Add("Currency")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "currency(dbl(value))"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("1.23")
var_Items.AddItem("2.34")
var_Items.AddItem("0")
var_Items.AddItem(5)
var_Items.AddItem("10000.99")
|
356
|
How can I display the column's header using multiple lines

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.HeaderHeight = 128
oComboBox.HeaderSingleLine = false
// oComboBox.Columns.Add("This is just a column that should break the header.").Width = 32
var_Column = oComboBox.Columns.Add("This is just a column that should break the header.")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Width = 32]
endwith
oComboBox.Columns.Add("This is just another column that should break the header.")
|
56
|
How can I display the column's filter

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("").DisplayFilterButton = true
var_Column = oComboBox.Columns.Add("")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.DisplayFilterButton = True]
endwith
|
416
|
How can I display only the right part of the cell

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("")
var_Column = oComboBox.Columns.Add("Right")
var_Column.ComputedField = "%0 right 2"
var_Column.FormatColumn = "'" + ["] + "' + value + '" + ["] + "'"
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
var_Items.InsertItem(h,null,"SChild 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
395
|
How can I display only the right part of the cell

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("")
var_Column = oComboBox.Columns.Add("Right")
var_Column.ComputedField = "%0 right 2"
var_Column.FormatColumn = "'" + ["] + "' + value + '" + ["] + "'"
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
var_Items.InsertItem(h,null,"SChild 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
380
|
How can I display only the month of the date

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("Month").ComputedField = "month(%0)"
var_Column = oComboBox.Columns.Add("Month")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "month(%0)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001 10:00:00")
var_Items.AddItem("02/02/2002 11:00:00")
var_Items.AddItem("03/03/2003 12:00:00")
var_Items.AddItem("04/04/2004 13:00:00")
|
394
|
How can I display only the left part of the cell

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("")
// oComboBox.Columns.Add("Left").ComputedField = "%0 left 2"
var_Column = oComboBox.Columns.Add("Left")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "%0 left 2"]
endwith
var_Items = oComboBox.Items
h = var_Items.AddItem("Root")
var_Items.InsertItem(h,null,"Child 1")
var_Items.InsertItem(h,null,"Child 2")
var_Items.InsertItem(h,null,"SChild 3")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
381
|
How can I display only the day of the date

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("Day").ComputedField = "day(%0)"
var_Column = oComboBox.Columns.Add("Day")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "day(%0)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/11/2001 10:00:00")
var_Items.AddItem("02/22/2002 11:00:00")
var_Items.AddItem("03/13/2003 12:00:00")
var_Items.AddItem("04/14/2004 13:00:00")
|
439
|
How can I display numbers with 2 digits in each group

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Def").Def(17) = 1
var_Column = oComboBox.Columns.Add("Def")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Items = oComboBox.Items
h = var_Items.AddItem(100000.27)
// var_Items.FormatCell(h,0) = "(value format '') + ' <fgcolor=808080>(default)'"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.FormatCell(h,0) = "(value format '') + ' <fgcolor=808080>(default)'"]
endwith
h = var_Items.AddItem(100000.27)
// var_Items.FormatCell(h,0) = "(value format '||2') + ' <fgcolor=808080>(grouping by 2 digits)'"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.FormatCell(h,0) = "(value format '||2') + ' <fgcolor=808080>(grouping by 2 digits)'"]
endwith
oComboBox.EndUpdate()
|
367
|
How can I display names as proper ( first leter of the word must be in uppercase, and the rest in lowercase )

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("").ComputedField = "proper(%0)"
var_Column = oComboBox.Columns.Add("")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "proper(%0)"]
endwith
var_Items = oComboBox.Items
h = var_Items.AddItem("root")
var_Items.InsertItem(h,null,"child child")
var_Items.InsertItem(h,null,"child child")
var_Items.InsertItem(h,null,"child child")
// var_Items.ExpandItem(h) = true
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ExpandItem(h) = True]
endwith
|
168
|
How can I display my text on the scroll bar, using a different font

local oComboBox,var_Column,var_Column1,var_Column2
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Template = [ScrollPartCaption(1,256) = "This is <s><font Tahoma;12> just </font></s> text"] // oComboBox.ScrollPartCaption(1,256) = "This is <s><font Tahoma;12> just </font></s> text"
oComboBox.ColumnAutoResize = false
oComboBox.ScrollHeight = 20
// oComboBox.Columns.Add("C1").Width = 256
var_Column = oComboBox.Columns.Add("C1")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Width = 256]
endwith
// oComboBox.Columns.Add("C2").Width = 256
var_Column1 = oComboBox.Columns.Add("C2")
with (oComboBox)
TemplateDef = [dim var_Column1]
TemplateDef = var_Column1
Template = [var_Column1.Width = 256]
endwith
// oComboBox.Columns.Add("C3").Width = 256
var_Column2 = oComboBox.Columns.Add("C3")
with (oComboBox)
TemplateDef = [dim var_Column2]
TemplateDef = var_Column2
Template = [var_Column2.Width = 256]
endwith
|
167
|
How can I display my text on the scroll bar, using a different font

local oComboBox,var_Column,var_Column1,var_Column2,var_StdFont
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Template = [ScrollPartCaption(1,256) = "This is just a text"] // oComboBox.ScrollPartCaption(1,256) = "This is just a text"
// oComboBox.ScrollFont(1).Size = 12
var_StdFont = oComboBox.ScrollFont(1)
with (oComboBox)
TemplateDef = [dim var_StdFont]
TemplateDef = var_StdFont
Template = [var_StdFont.Size = 12]
endwith
oComboBox.ColumnAutoResize = false
oComboBox.ScrollHeight = 20
// oComboBox.Columns.Add("C1").Width = 256
var_Column = oComboBox.Columns.Add("C1")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Width = 256]
endwith
// oComboBox.Columns.Add("C2").Width = 256
var_Column1 = oComboBox.Columns.Add("C2")
with (oComboBox)
TemplateDef = [dim var_Column1]
TemplateDef = var_Column1
Template = [var_Column1.Width = 256]
endwith
// oComboBox.Columns.Add("C3").Width = 256
var_Column2 = oComboBox.Columns.Add("C3")
with (oComboBox)
TemplateDef = [dim var_Column2]
TemplateDef = var_Column2
Template = [var_Column2.Width = 256]
endwith
|
166
|
How can I display my text on the scroll bar

local oComboBox,var_Column,var_Column1,var_Column2
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Template = [ScrollPartCaption(1,256) = "this is just a text"] // oComboBox.ScrollPartCaption(1,256) = "this is just a text"
oComboBox.ColumnAutoResize = false
// oComboBox.Columns.Add("C1").Width = 256
var_Column = oComboBox.Columns.Add("C1")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Width = 256]
endwith
// oComboBox.Columns.Add("C2").Width = 256
var_Column1 = oComboBox.Columns.Add("C2")
with (oComboBox)
TemplateDef = [dim var_Column1]
TemplateDef = var_Column1
Template = [var_Column1.Width = 256]
endwith
// oComboBox.Columns.Add("C3").Width = 256
var_Column2 = oComboBox.Columns.Add("C3")
with (oComboBox)
TemplateDef = [dim var_Column2]
TemplateDef = var_Column2
Template = [var_Column2.Width = 256]
endwith
|
438
|
How can I display my numbers using a different decimal separator

local h,oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
// oComboBox.Columns.Add("Def").Def(17) = 1
var_Column = oComboBox.Columns.Add("Def")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Items = oComboBox.Items
h = var_Items.AddItem(100.27)
// var_Items.FormatCell(h,0) = "(value format '') + ' <fgcolor=808080>(default)'"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.FormatCell(h,0) = "(value format '') + ' <fgcolor=808080>(default)'"]
endwith
h = var_Items.AddItem(100.27)
// var_Items.FormatCell(h,0) = "(value format '|;') + ' <fgcolor=808080>(decimal separator is <b>;</b>)'"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.FormatCell(h,0) = "(value format '|;') + ' <fgcolor=808080>(decimal separator is <b>;</b>)'"]
endwith
oComboBox.EndUpdate()
|
414
|
How can I display icons or images instead numbers

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
var_Column = oComboBox.Columns.Add("Icons")
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Column.FormatColumn = "'The cell displays the icon <img>'+value+'</img> instead ' + value"
var_Items = oComboBox.Items
var_Items.AddItem(1)
var_Items.AddItem(2)
var_Items.AddItem(3)
|
392
|
How can I display icons or images instead numbers

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTqlVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/yNAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=")
var_Column = oComboBox.Columns.Add("Icons")
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Column.FormatColumn = "'The cell displays the icon <img>'+value+'</img> instead ' + value"
var_Items = oComboBox.Items
var_Items.AddItem(1)
var_Items.AddItem(2)
var_Items.AddItem(3)
|
397
|
How can I display dates in short format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Date").FormatColumn = "shortdate(value)"
var_Column = oComboBox.Columns.Add("Date")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "shortdate(value)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001")
var_Items.AddItem("02/02/2002")
var_Items.AddItem("03/03/2003")
var_Items.AddItem("04/04/2004")
|
375
|
How can I display dates in short format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("ShortFormat").ComputedField = "shortdate(%0)"
var_Column = oComboBox.Columns.Add("ShortFormat")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "shortdate(%0)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001 10:00:00")
var_Items.AddItem("02/02/2002 11:00:00")
var_Items.AddItem("03/03/2003 12:00:00")
var_Items.AddItem("04/04/2004 13:00:00")
|
418
|
How can I display dates in short format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Date").FormatColumn = "shortdate(value)"
var_Column = oComboBox.Columns.Add("Date")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "shortdate(value)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001")
var_Items.AddItem("02/02/2002")
var_Items.AddItem("03/03/2003")
var_Items.AddItem("04/04/2004")
|
419
|
How can I display dates in my format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("Date")
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Column.FormatColumn = "'<b>' + year(0:=date(value)) + '</b><fgcolor=808080><font ;6> (' + month(=:0) + ' - ' + day(=:0) +')'"
var_Items = oComboBox.Items
var_Items.AddItem("01/21/2001")
var_Items.AddItem("02/22/2002")
var_Items.AddItem("03/13/2003")
var_Items.AddItem("04/24/2004")
|
398
|
How can I display dates in my format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
var_Column = oComboBox.Columns.Add("Date")
// var_Column.Def(17) = 1
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
var_Column.FormatColumn = "'<b>' + year(0:=date(value)) + '</b><fgcolor=808080><font ;6> (' + month(=:0) + ' - ' + day(=:0) +')'"
var_Items = oComboBox.Items
var_Items.AddItem("01/21/2001")
var_Items.AddItem("02/22/2002")
var_Items.AddItem("03/13/2003")
var_Items.AddItem("04/24/2004")
|
417
|
How can I display dates in long format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Date").FormatColumn = "longdate(value)"
var_Column = oComboBox.Columns.Add("Date")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "longdate(value)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001")
var_Items.AddItem("02/02/2002")
var_Items.AddItem("03/03/2003")
var_Items.AddItem("04/04/2004")
|
396
|
How can I display dates in long format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("Date").FormatColumn = "longdate(value)"
var_Column = oComboBox.Columns.Add("Date")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.FormatColumn = "longdate(value)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001")
var_Items.AddItem("02/02/2002")
var_Items.AddItem("03/03/2003")
var_Items.AddItem("04/04/2004")
|
376
|
How can I display dates in long format

local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.Columns.Add("Date")
// oComboBox.Columns.Add("LongFormat").ComputedField = "longdate(%0)"
var_Column = oComboBox.Columns.Add("LongFormat")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ComputedField = "longdate(%0)"]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("01/01/2001 10:00:00")
var_Items.AddItem("02/02/2002 11:00:00")
var_Items.AddItem("03/03/2003 12:00:00")
var_Items.AddItem("04/04/2004 13:00:00")
|
271
|
How can I display an item or a cell on multiple lines

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.ScrollBySingleLine = true
oComboBox.Columns.Add("C1")
oComboBox.Columns.Add("C2")
var_Items = oComboBox.Items
h = var_Items.AddItem("Cell 1")
// var_Items.CellCaption(h,1) = "This is bit of text that's shown on multiple lines"
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "This is bit of text that's shown on multiple lines"]
endwith
// var_Items.CellSingleLine(h,1) = false
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellSingleLine(h,1) = False]
endwith
|
198
|
How can I display all cells using multiple lines

local oComboBox,var_Column,var_Column1,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("MultipleLine").Def(16) = false
var_Column = oComboBox.Columns.Add("MultipleLine")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(16) = False]
endwith
// oComboBox.Columns.Add("SingleLine").Def(16) = true
var_Column1 = oComboBox.Columns.Add("SingleLine")
with (oComboBox)
TemplateDef = [dim var_Column1]
TemplateDef = var_Column1
Template = [var_Column1.Def(16) = True]
endwith
var_Items = oComboBox.Items
// var_Items.CellCaption(var_Items.AddItem("This is a bit of long text that should break the line"),1) = "this is a bit of long text that's displayed on a single line"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("This is a bit of long text that should break the line"),1) = "this is a bit of long text that's displayed on a single line"]
endwith
|
199
|
How can I display all cells using HTML format

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("HTML").Def(17) = 1
var_Column = oComboBox.Columns.Add("HTML")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
oComboBox.Items.AddItem("<font ;12>T</font>his <b>is</b> an <a>html</a> <font Tahoma><fgcolor=FF0000>text</fgcolor></font>.")
|
190
|
How can I display a tooltip when the cursor hovers the column

local oComboBox,var_Column
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
// oComboBox.Columns.Add("tooltip").ToolTip = "This is a bit of text that is shown when user hovers the column."
var_Column = oComboBox.Columns.Add("tooltip")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.ToolTip = "This is a bit of text that is shown when user hovers the column."]
endwith
|
159
|
How can I display a multiple pictures to a cell or item

local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.DefaultItemHeight = 48
oComboBox.Template = [HTMLPicture("pic1") = "c:\exontrol\images\zipdisk.gif"] // oComboBox.HTMLPicture("pic1") = "c:\exontrol\images\zipdisk.gif"
oComboBox.Template = [HTMLPicture("pic2") = "c:\exontrol\images\auction.gif"] // oComboBox.HTMLPicture("pic2") = "c:\exontrol\images\auction.gif"
oComboBox.Columns.Add("C1")
var_Items = oComboBox.Items
// var_Items.CellCaptionFormat(var_Items.AddItem("<img>pic1</img> Text <img>pic2</img> another text ..."),0) = 1
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaptionFormat(AddItem("<img>pic1</img> Text <img>pic2</img> another text ..."),0) = 1]
endwith
|
406
|
How can I display a filter field in the bottom part of the drop down portion

local oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.FilterForVisible = true
oComboBox.IntegralHeight = true
oComboBox.Columns.Add("Default")
var_Items = oComboBox.Items
var_Items.AddItem("Item 1")
var_Items.AddItem("Item 2")
var_Items.AddItem("Item 3")
var_Items.AddItem("Item 4")
var_Items.AddItem("Item 5")
oComboBox.EndUpdate()
|
310
|
How can I display a divider item, merging all cells

local h,oComboBox,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.MarkSearchColumn = false
oComboBox.TreeColumnIndex = -1
oComboBox.Columns.Add("C1")
oComboBox.Columns.Add("C2")
var_Items = oComboBox.Items
h = var_Items.AddItem("Cell 1")
// var_Items.CellCaption(h,1) = "This is bit of text that's shown on multiple lines. This is bit of text that's shown on multiple lines."
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellCaption(h,1) = "This is bit of text that's shown on multiple lines. This is bit of text that's shown on multiple lines."]
endwith
// var_Items.CellSingleLine(h,1) = false
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellSingleLine(h,1) = False]
endwith
h = var_Items.AddItem("This is bit of text that's displayed on the entire item, divider.")
// var_Items.ItemDivider(h) = 0
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.ItemDivider(h) = 0]
endwith
// var_Items.CellHAlignment(h,0) = 1
with (oComboBox)
TemplateDef = [dim var_Items,h]
TemplateDef = var_Items
TemplateDef = h
Template = [var_Items.CellHAlignment(h,0) = 1]
endwith
|
485
|
How can I display a different column, on the control's label (method 2)

local oComboBox,var_Column,var_Column1,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.Style = 2
oComboBox.SingleEdit = true
oComboBox.LabelColumnIndex = 1
oComboBox.DrawGridLines = 2
// oComboBox.Columns.Add("Column 1").Def(17) = 1
var_Column = oComboBox.Columns.Add("Column 1")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
// oComboBox.Columns.Add("Column 2").Def(17) = 1
var_Column1 = oComboBox.Columns.Add("Column 2")
with (oComboBox)
TemplateDef = [dim var_Column1]
TemplateDef = var_Column1
Template = [var_Column1.Def(17) = 1]
endwith
var_Items = oComboBox.Items
// var_Items.CellCaption(var_Items.AddItem("Item 1 on <b>Column 1"),1) = "Item 1 on <b>Column 2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Item 1 on <b>Column 1"),1) = "Item 1 on <b>Column 2"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Item 2 on <b>Column 1"),1) = "Item 2 on <b>Column 2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Item 2 on <b>Column 1"),1) = "Item 2 on <b>Column 2"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Item 3 on <b>Column 1"),1) = "Item 3 on <b>Column 2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Item 3 on <b>Column 1"),1) = "Item 3 on <b>Column 2"]
endwith
// var_Items.SelectItem(var_Items.FirstVisibleItem) = true
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.SelectItem(FirstVisibleItem) = True]
endwith
oComboBox.EndUpdate()
|
484
|
How can I display a different column, on the control's label (method 1)

local oComboBox,var_Column,var_Column1,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.Style = 2
oComboBox.SingleEdit = true
oComboBox.SearchColumnIndex = 1
oComboBox.DrawGridLines = 2
// oComboBox.Columns.Add("Column 1").Def(17) = 1
var_Column = oComboBox.Columns.Add("Column 1")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(17) = 1]
endwith
// oComboBox.Columns.Add("Column 2").Def(17) = 1
var_Column1 = oComboBox.Columns.Add("Column 2")
with (oComboBox)
TemplateDef = [dim var_Column1]
TemplateDef = var_Column1
Template = [var_Column1.Def(17) = 1]
endwith
var_Items = oComboBox.Items
// var_Items.CellCaption(var_Items.AddItem("Item 1 on <b>Column 1"),1) = "Item 1 on <b>Column 2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Item 1 on <b>Column 1"),1) = "Item 1 on <b>Column 2"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Item 2 on <b>Column 1"),1) = "Item 2 on <b>Column 2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Item 2 on <b>Column 1"),1) = "Item 2 on <b>Column 2"]
endwith
// var_Items.CellCaption(var_Items.AddItem("Item 3 on <b>Column 1"),1) = "Item 3 on <b>Column 2"
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.CellCaption(AddItem("Item 3 on <b>Column 1"),1) = "Item 3 on <b>Column 2"]
endwith
// var_Items.SelectItem(var_Items.FirstVisibleItem) = true
with (oComboBox)
TemplateDef = [dim var_Items]
TemplateDef = var_Items
Template = [var_Items.SelectItem(FirstVisibleItem) = True]
endwith
oComboBox.EndUpdate()
|
410
|
How can I display a different caption in the label area, when I click the cell's check box

/*
with (this.EXCOMBOBOXACTIVEXCONTROL1.nativeObject)
CellStateChanged = class::nativeObject_CellStateChanged
endwith
*/
// Fired after cell's state has been changed.
function nativeObject_CellStateChanged(Cell)
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.LabelText = Str(Cell)
? Str(oComboBox.Items.CellCaption(0,Cell))
? Str(oComboBox.Items.CellState(0,Cell))
return
local oComboBox,var_Column,var_Items
oComboBox = form.EXCOMBOBOXACTIVEXCONTROL1.nativeObject
oComboBox.BeginUpdate()
oComboBox.Style = 2
oComboBox.IntegralHeight = true
oComboBox.HeaderVisible = false
oComboBox.SingleEdit = true
oComboBox.SearchColumnIndex = -1
oComboBox.AdjustSearchColumn = false
// oComboBox.Columns.Add("Language").Def(0) = true
var_Column = oComboBox.Columns.Add("Language")
with (oComboBox)
TemplateDef = [dim var_Column]
TemplateDef = var_Column
Template = [var_Column.Def(0) = True]
endwith
var_Items = oComboBox.Items
var_Items.AddItem("English")
var_Items.AddItem("Hebrew")
var_Items.AddItem("Spanish")
oComboBox.LabelText = " <b>custom</b> text "
oComboBox.EndUpdate()
|